package com.example.code.thread;

import cn.hutool.http.HttpUtil;

/**
 * 1、继承Thread类实现多线程
 */
public class MyThread extends Thread {
    public void run() {
        for (int i = 0; i < 10; i++) {
            String s = HttpUtil.get("http://localhost:8080/dzjj/jp/gysxm/test.htm");
            System.out.println(s);
        }
    }


    public static void main(String[] args) {
        for (int i = 0; i < 20; i++) {
            MyThread myThread1 = new MyThread();
            myThread1.start();
        }
    }
}
